<?php
// +----------------------------------------------------------------------
// |
// +----------------------------------------------------------------------
// |
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// |
// +----------------------------------------------------------------------

namespace app\model;

use \think\Model;

class UserInvite extends Model
{
    protected $name = 'user_invite';
    protected $autoWriteTimestamp = true;
    protected $insert = [];
    protected $update = [];

    public function user()
    {
        return $this
            ->belongsTo('User', 'user_id')
            ->bind([
                'nickname' => 'nickname',
                'avatar'   => 'avatar',
                'token'    => 'token',
            ]);
    }
}
